package com.xiaooqi.springboot.bean;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * @Author Rookie Coder
 * @Description
 * @Date
 **/
@Component // 表示将这个类加入到spring的容器中
@ConfigurationProperties(prefix = "school")
public class School {

    private String name;

    private String index;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getIndex() {
        return index;
    }

    public void setIndex(String index) {
        this.index = index;
    }

    @Override
    public String toString() {
        return "School{" +
                "name='" + name + '\'' +
                ", index='" + index + '\'' +
                '}';
    }
}
